home *** CD-ROM | disk | FTP | other *** search
/ Mac Mania 1 / MacMania 1.toast / Games / Birthday / card_4285.txt < prev    next >
Text File  |  1990-09-09  |  13KB  |  471 lines

  1. -- card: 4285 from stack: in
  2. -- bmap block id: 2343
  3. -- flags: 4000
  4. -- background id: 2739
  5. -- name: Birthday
  6. ----- HyperTalk script -----
  7. on openCard
  8.   hide Menubar
  9.   ask "What is your name?" with "Bozo"
  10.   put It into Bname
  11.   ask "In what year were you born?" with "1957"
  12.   put It into Byear
  13.   if Byear is " " then
  14.     beep
  15.     ask "Which year?"
  16.   end if
  17.   put It into Byear
  18.   ask "In what month were you born?" with "Mar"
  19.   put It into Bmonth
  20.   if Bmonth is " " then
  21.     beep
  22.     ask "Which month?"
  23.   end if
  24.   put It into Bmonth
  25.   if length of Bmonth > 3 then
  26.     put char 1 of Bmonth & char 2 of Bmonth & char 3 of Bmonth into Bmonth
  27.   end if
  28.   ask "On what day were you born?" with "12"
  29.   put It into Bday
  30.   if Bday is " " then
  31.     beep
  32.     ask "Which day?"
  33.   end if
  34.   put It into Bday
  35.   if Bday > 31 then put 31 into Bday
  36.   answer "Thanks, "&Bname
  37.   put Bmonth&" "&Bday&", "&Byear into card field "Date" of card "Birthday"
  38.   put Byear - 1902 into lineno
  39.   put line lineno of field 1 of card "Headline" into card field "Hline" of card "Birthday"
  40.   put line lineno of field 1 of card "Nobel" into card field "Nobel" of card "Birthday"
  41.   put word 3 of line lineno of field 1 of card "Sports" into league
  42.   if league is "A" then
  43.     put "American" into league
  44.   else
  45.     put "National" into league
  46.   end if
  47.   put "World Series won by "&league&" League: "& word 2 of line lineno of field 1 of card "Sports" into card field "WSeries" of card "Birthday"
  48.   put "Ky Derby winner: "&word 4 of line lineno of field 1 of card "Sports" into card field "Derby" of card "Birthday"
  49.   put "Tennis Davis Cup won by: "&word 5 of line lineno of field 1 of card "Sports" into card field "Davis" of card "Birthday"
  50.   if Byear > 1910 then
  51.     put "Indy 500 winning driver: "&word 6 of line lineno of field 1 of card "Sports" into card field "Indy500" of card "Birthday"
  52.   end if
  53.   if Byear > 1936 then
  54.     put "NCAA Football Champs: "&word 7 of line lineno of field 1 of card "Sports" into card field "NCAA" of card "Birthday"
  55.   end if
  56.   if Byear > 1966 then
  57.     put "SuperBowl winner: " & word 8 of line lineno of field 1 of card "Sports" into card field "SBowl" of card "Birthday"
  58.   end if
  59.   put Bname into card field "Bname" of card "Birthday"
  60.   put Bday + 2 into lineno
  61.   put line lineno of field 1 of card Bmonth into card field "Famous" of card "Birthday"
  62.   put line 1 of field 1 of card Bmonth into card field "Birthstone" of card "Birthday"
  63.   put line 2 of field 1 of card Bmonth into card field "Birthflower" of card "Birthday"
  64.   if Byear > 1927 then
  65.     put Byear - 1927 into lineno
  66.     put word 2 of line lineno of field 1 of card "Oscar" into card field "Actress" of card "Birthday"
  67.     put word 3 of line lineno of field 1 of card "Oscar" into card field "Actor" of card "Birthday"
  68.     put empty into title
  69.     put empty into thisword
  70.     repeat with count = 4 to 10
  71.       put word count of line lineno of field 1 of card "Oscar" into thisword
  72.       put title &" "& thisword into title
  73.     end repeat
  74.     put title into card field "BestPic" of card Birthday
  75.   end if
  76.   if Bmonth is "Jan" and Bday < 21 then
  77.     put "CAPRICORN Dec 22 - Jan 20" into card field "Zodiac"
  78.   else if Bmonth is "Jan" and Bday > 20 then
  79.     put "AQUARIUS Jan 21 - Feb 19" into card field "Zodiac"
  80.   else if Bmonth is "Feb" and Bday < 20 then
  81.     put "AQUARIUS Jan 21 - Feb 19" into card field "Zodiac"
  82.   else if Bmonth is "Feb" and Bday > 19 then
  83.     put "PISCES Feb 20 - Mar 20" into card field "Zodiac"
  84.   else if Bmonth is "Mar" and Bday < 21 then
  85.     put "PISCES Feb 20 - Mar 20" into card field "Zodiac"
  86.   else if Bmonth is "Mar" and Bday > 20 then
  87.     put "ARIES Mar 21 - Apr 19" into card field "Zodiac"
  88.   else if Bmonth is "Apr" and Bday < 20 then
  89.     put "ARIES Mar 21 - Apr 19" into card field "Zodiac"
  90.   else if Bmonth is "Apr" and Bday > 19 then
  91.     put "TAURUS Apr 20 - May 20" into card field "Zodiac"
  92.   else if Bmonth is "May" and Bday < 21 then
  93.     put "TAURUS Apr 20 - May 20" into card field "Zodiac"
  94.   else if Bmonth is "May" and Bday > 20 then
  95.     put "GEMINI May 21 - Jun 21" into card field "Zodiac"
  96.   else if Bmonth is "Jun" and Bday < 22 then
  97.     put "GEMINI May 21 - Jun 21" into card field "Zodiac"
  98.   else if Bmonth is "Jun" and Bday > 21 then
  99.     put "CANCER Jun 22 - Jul 21" into card field "Zodiac"
  100.   else if Bmonth is "Jul" and Bday < 22 then
  101.     put "CANCER Jun 22 - Jul 21" into card field "Zodiac"
  102.   else if Bmonth is "Jul" and Bday > 21 then
  103.     put "LEO Jul 22 - Aug 21" into card field "Zodiac"
  104.   else if Bmonth is "Aug" and Bday < 22 then
  105.     put "LEO Jul 22 - Aug 21" into card field "Zodiac"
  106.   else if Bmonth is "Aug" and Bday > 21 then
  107.     put "VIRGO Aug 22 - Sep 22" into card field "Zodiac"
  108.   else if Bmonth is "Sep" and Bday < 23 then
  109.     put "VIRGO Aug 22 - Sep 22" into card field "Zodiac"
  110.   else if Bmonth is "Sep" and Bday > 22 then
  111.     put "LIBRA Sep 23 - Oct 22" into card field "Zodiac"
  112.   else if Bmonth is "Oct" and Bday < 23 then
  113.     put "LIBRA Sep 23 - Oct 22" into card field "Zodiac"
  114.   else if Bmonth is "Oct" and Bday > 22 then
  115.     put "SCORPIO Oct 23 - Nov 21" into card field "Zodiac"
  116.   else if Bmonth is "Nov" and Bday < 22 then
  117.     put "SCORPIO Oct 23 - Nov 21" into card field "Zodiac"
  118.   else if Bmonth is "Nov" and Bday > 21 then
  119.     put "SAGITTARIUS Nov 22 - Dec 21" into card field "Zodiac"
  120.   else if Bmonth is "Dec" and Bday < 22 then
  121.     put "SAGITTARIUS Nov 22 - Dec 21" into card field "Zodiac"
  122.   else if Bmonth is "Dec" and Bday > 21 then
  123.     put "CAPRICORN Dec 22 - Jan 20" into card field "Zodiac"
  124.     put 1 into horo
  125.   end if
  126.   if Byear/4 = trunc(Byear/4) then
  127.     put (Byear/4)-475 into lineno
  128.     put line lineno of field 1 of card "Olympics" into oly
  129.     if oly is not empty then
  130.       put "Olympics at: " & oly into card field "Olympics" of card "Birthday"
  131.     end if
  132.   end if
  133.   if Byear = 1906 then put "Olympics held in Athens" into card field "Olympics" of card "Birthday"
  134. end openCard
  135.  
  136. on closeCard
  137.   repeat with count = 1 to 18
  138.     put empty into card field count
  139.   end repeat
  140. end closeCard
  141.  
  142.  
  143. -- part 1 (button)
  144. -- low flags: 00
  145. -- high flags: 0000
  146. -- rect: left=11 top=34 right=64 bottom=49
  147. -- title width / last selected line: 0
  148. -- icon id / first selected line: 1011 / 1011
  149. -- text alignment: 1
  150. -- font id: 0
  151. -- text size: 12
  152. -- style flags: 0
  153. -- line height: 16
  154. -- part name: 
  155. ----- HyperTalk script -----
  156. on mouseUp
  157.   visual effect iris close
  158.   go home
  159. end mouseUp
  160.  
  161.  
  162.  
  163. -- part 2 (button)
  164. -- low flags: 00
  165. -- high flags: 0000
  166. -- rect: left=49 top=34 right=64 bottom=78
  167. -- title width / last selected line: 0
  168. -- icon id / first selected line: 9761 / 9761
  169. -- text alignment: 1
  170. -- font id: 0
  171. -- text size: 12
  172. -- style flags: 0
  173. -- line height: 16
  174. -- part name: 
  175. ----- HyperTalk script -----
  176. on mouseUp
  177.   visual effect dissolve
  178.   go to next card
  179. end mouseUp
  180.  
  181.  
  182.  
  183. -- part 3 (field)
  184. -- low flags: 00
  185. -- high flags: 0000
  186. -- rect: left=384 top=40 right=56 bottom=491
  187. -- title width / last selected line: 0
  188. -- icon id / first selected line: 0 / 0
  189. -- text alignment: 1
  190. -- font id: 3
  191. -- text size: 10
  192. -- style flags: 256
  193. -- line height: 13
  194. -- part name: Date
  195.  
  196.  
  197. -- part 4 (field)
  198. -- low flags: 00
  199. -- high flags: 0002
  200. -- rect: left=10 top=63 right=89 bottom=489
  201. -- title width / last selected line: 0
  202. -- icon id / first selected line: 0 / 0
  203. -- text alignment: 1
  204. -- font id: 3
  205. -- text size: 20
  206. -- style flags: 256
  207. -- line height: 26
  208. -- part name: HLine
  209.  
  210.  
  211. -- part 5 (field)
  212. -- low flags: 00
  213. -- high flags: 0002
  214. -- rect: left=319 top=111 right=162 bottom=489
  215. -- title width / last selected line: 0
  216. -- icon id / first selected line: 0 / 0
  217. -- text alignment: 1
  218. -- font id: 3
  219. -- text size: 12
  220. -- style flags: 256
  221. -- line height: 16
  222. -- part name: WSeries
  223.  
  224.  
  225. -- part 7 (field)
  226. -- low flags: 00
  227. -- high flags: 0002
  228. -- rect: left=319 top=192 right=224 bottom=489
  229. -- title width / last selected line: 0
  230. -- icon id / first selected line: 0 / 0
  231. -- text alignment: 1
  232. -- font id: 3
  233. -- text size: 12
  234. -- style flags: 256
  235. -- line height: 16
  236. -- part name: Davis
  237.  
  238.  
  239. -- part 8 (field)
  240. -- low flags: 00
  241. -- high flags: 0002
  242. -- rect: left=319 top=222 right=255 bottom=489
  243. -- title width / last selected line: 0
  244. -- icon id / first selected line: 0 / 0
  245. -- text alignment: 1
  246. -- font id: 3
  247. -- text size: 12
  248. -- style flags: 256
  249. -- line height: 16
  250. -- part name: Indy500
  251.  
  252.  
  253. -- part 9 (field)
  254. -- low flags: 00
  255. -- high flags: 0002
  256. -- rect: left=319 top=254 right=286 bottom=489
  257. -- title width / last selected line: 0
  258. -- icon id / first selected line: 0 / 0
  259. -- text alignment: 1
  260. -- font id: 3
  261. -- text size: 12
  262. -- style flags: 256
  263. -- line height: 16
  264. -- part name: NCAA
  265.  
  266.  
  267. -- part 10 (field)
  268. -- low flags: 00
  269. -- high flags: 0002
  270. -- rect: left=319 top=285 right=318 bottom=489
  271. -- title width / last selected line: 0
  272. -- icon id / first selected line: 0 / 0
  273. -- text alignment: 1
  274. -- font id: 3
  275. -- text size: 12
  276. -- style flags: 256
  277. -- line height: 16
  278. -- part name: SBowl
  279.  
  280.  
  281. -- part 11 (field)
  282. -- low flags: 00
  283. -- high flags: 0002
  284. -- rect: left=319 top=161 right=193 bottom=489
  285. -- title width / last selected line: 0
  286. -- icon id / first selected line: 0 / 0
  287. -- text alignment: 1
  288. -- font id: 3
  289. -- text size: 12
  290. -- style flags: 256
  291. -- line height: 16
  292. -- part name: Derby
  293.  
  294.  
  295. -- part 12 (field)
  296. -- low flags: 00
  297. -- high flags: 0002
  298. -- rect: left=11 top=108 right=128 bottom=181
  299. -- title width / last selected line: 0
  300. -- icon id / first selected line: 0 / 0
  301. -- text alignment: 1
  302. -- font id: 3
  303. -- text size: 12
  304. -- style flags: 256
  305. -- line height: 16
  306. -- part name: Bname
  307.  
  308.  
  309. -- part 13 (field)
  310. -- low flags: 00
  311. -- high flags: 0002
  312. -- rect: left=11 top=126 right=160 bottom=181
  313. -- title width / last selected line: 0
  314. -- icon id / first selected line: 0 / 0
  315. -- text alignment: 1
  316. -- font id: 3
  317. -- text size: 12
  318. -- style flags: 256
  319. -- line height: 16
  320. -- part name: Famous
  321.  
  322.  
  323. -- part 14 (button)
  324. -- low flags: 00
  325. -- high flags: 0000
  326. -- rect: left=78 top=34 right=64 bottom=107
  327. -- title width / last selected line: 0
  328. -- icon id / first selected line: 26635 / 26635
  329. -- text alignment: 1
  330. -- font id: 0
  331. -- text size: 12
  332. -- style flags: 0
  333. -- line height: 16
  334. -- part name: 
  335. ----- HyperTalk script -----
  336. on mouseUp
  337.   answer "by Ed & Barb Will Jan 88"
  338. end mouseUp
  339.  
  340.  
  341.  
  342. -- part 15 (field)
  343. -- low flags: 00
  344. -- high flags: 0002
  345. -- rect: left=10 top=173 right=189 bottom=181
  346. -- title width / last selected line: 0
  347. -- icon id / first selected line: 0 / 0
  348. -- text alignment: 1
  349. -- font id: 3
  350. -- text size: 10
  351. -- style flags: 256
  352. -- line height: 13
  353. -- part name: Birthstone
  354.  
  355.  
  356. -- part 16 (field)
  357. -- low flags: 00
  358. -- high flags: 0002
  359. -- rect: left=11 top=238 right=269 bottom=181
  360. -- title width / last selected line: 0
  361. -- icon id / first selected line: 0 / 0
  362. -- text alignment: 1
  363. -- font id: 3
  364. -- text size: 12
  365. -- style flags: 256
  366. -- line height: 16
  367. -- part name: Zodiac
  368.  
  369.  
  370. -- part 17 (field)
  371. -- low flags: 00
  372. -- high flags: 0000
  373. -- rect: left=11 top=268 right=318 bottom=184
  374. -- title width / last selected line: 0
  375. -- icon id / first selected line: 0 / 0
  376. -- text alignment: 1
  377. -- font id: 3
  378. -- text size: 12
  379. -- style flags: 256
  380. -- line height: 16
  381. -- part name: Olympics
  382.  
  383.  
  384. -- part 18 (field)
  385. -- low flags: 00
  386. -- high flags: 0002
  387. -- rect: left=180 top=126 right=174 bottom=320
  388. -- title width / last selected line: 0
  389. -- icon id / first selected line: 0 / 0
  390. -- text alignment: 1
  391. -- font id: 3
  392. -- text size: 12
  393. -- style flags: 256
  394. -- line height: 16
  395. -- part name: BestPic
  396.  
  397.  
  398. -- part 19 (field)
  399. -- low flags: 00
  400. -- high flags: 0002
  401. -- rect: left=180 top=188 right=207 bottom=320
  402. -- title width / last selected line: 0
  403. -- icon id / first selected line: 0 / 0
  404. -- text alignment: 1
  405. -- font id: 3
  406. -- text size: 12
  407. -- style flags: 256
  408. -- line height: 16
  409. -- part name: Actress
  410.  
  411.  
  412. -- part 20 (field)
  413. -- low flags: 00
  414. -- high flags: 0002
  415. -- rect: left=180 top=222 right=239 bottom=320
  416. -- title width / last selected line: 0
  417. -- icon id / first selected line: 0 / 0
  418. -- text alignment: 1
  419. -- font id: 3
  420. -- text size: 12
  421. -- style flags: 256
  422. -- line height: 16
  423. -- part name: Actor
  424.  
  425.  
  426. -- part 21 (button)
  427. -- low flags: 00
  428. -- high flags: 0000
  429. -- rect: left=351 top=33 right=64 bottom=387
  430. -- title width / last selected line: 0
  431. -- icon id / first selected line: 1007 / 1007
  432. -- text alignment: 1
  433. -- font id: 0
  434. -- text size: 12
  435. -- style flags: 0
  436. -- line height: 16
  437. -- part name: 
  438. ----- HyperTalk script -----
  439. on mouseUp
  440.   doMenu print card
  441. end mouseUp
  442.  
  443.  
  444.  
  445. -- part 22 (field)
  446. -- low flags: 00
  447. -- high flags: 0002
  448. -- rect: left=180 top=268 right=318 bottom=320
  449. -- title width / last selected line: 0
  450. -- icon id / first selected line: 0 / 0
  451. -- text alignment: 1
  452. -- font id: 3
  453. -- text size: 12
  454. -- style flags: 256
  455. -- line height: 16
  456. -- part name: Nobel
  457.  
  458.  
  459. -- part 23 (field)
  460. -- low flags: 00
  461. -- high flags: 0002
  462. -- rect: left=10 top=206 right=223 bottom=181
  463. -- title width / last selected line: 0
  464. -- icon id / first selected line: 0 / 0
  465. -- text alignment: 1
  466. -- font id: 3
  467. -- text size: 10
  468. -- style flags: 256
  469. -- line height: 13
  470. -- part name: Birthflower
  471.